Concatenate Object Heading (Level 1) and object text (Level 3)

The structure of my DOORS objects is as follows

BUSINESS PROCESS NAME - Object Heading - Level 1
subprocess name - object heading - Level 2
statement 1 - object text - level 3
statement 2 - object text - level 3
statement 3 -object text - level 3

I want to create a layout DXL column that concatenates the BUSINESS PROCESS NAME to each of the statements

the result of the concatenation would be
i.e BUSINESS PROCESS NAME: statement1
BUSINESS PROCESS NAME: statement2
BUSINESS PROCESS NAME: statement3
Any help with writing DXL is greatly appreciated
dxlnovice - Wed Jan 13 22:08:57 EST 2010

Re: Concatenate Object Heading (Level 1) and object text (Level 3)
Peter_Albert - Thu Jan 14 03:05:18 EST 2010

You need the 'parent' perm (twice) to get the level 1 heading object. The rest is buffer concatenation.

Try the following:
 

Object grandParentObj = null
Buffer buf = create
Buffer tmp = create
int iLevel = level obj
if (iLevel == 3)
{
  grandParentObj = parent parent obj
  tmp = obj."Object Text"
  buf = grandParentObj."Object Heading"
  buf += ": "
  buf += tmp 
  display tempStringOf buf
}
delete buf
delete tmp

 


Regards,

Peter

 

Re: Concatenate Object Heading (Level 1) and object text (Level 3)
dxlnovice - Thu Jan 14 12:37:33 EST 2010

Peter,

Your script worked perfectly fine. thank you so much.